package org.example.protocol;

/*
rpc调用结果报文
 */
public class RpcResponse extends Packet {
    // 状态码
    private int code;
    // 结果
    private Object result;

    @Override
    public Byte getCommand() {
        return 2;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public Object getResult() {
        return result;
    }

    public void setResult(Object result) {
        this.result = result;
    }

    @Override
    public String toString() {
        return "RprResponse{" +
                "code=" + code +
                ", result=" + result +
                '}';
    }
}
